-
Notifications
You must be signed in to change notification settings - Fork 24.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compute latest snapshot directly in TransportGetShardSnapshotAction #76254
Conversation
Pinging @elastic/es-distributed (Team:Distributed) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
for (String workingRepoName : workingRepoNames) { | ||
createSnapshot(workingRepoName, "empty-snap", Collections.singletonList(indexName)); | ||
latestSnapshot = createSnapshot(workingRepoName, "empty-snap-" + snapshotIdx++, Collections.singletonList(indexName)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm fine with giving all the snapshots unique names, but I'm curious whether this was necessary (and why).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These snapshots can take a short time to finish and some might overlap, in that case we need some tie breaker and I decided to use the name.
@elasticmachine update branch |
@elasticmachine run elasticsearch-ci/part-1 |
@elasticmachine run tests |
@elasticmachine update branch |
As discussed in #75840 now we compute the latest snapshot directly in
TransportGetShardSnapshotAction
andGetShardSnapshotResponse
just contains the latest snapshot for the shard.I used the
snapshotId
as a tiebreaker for the snapshot ordering, even though I think that should be rare enough outside of tests.Relates #73496